
<?php
 if($responseResult['total_num']!='0'){
?>
 
    <!-- 回应列表begin -->
	<dl class="reply_box">
	 <dt>共有<?php echo $responseResult['total_num'];?>个回应：</dt>
			
	<?php
		$responseCount = 1;
		
		if($responseResult['result']){
		
			foreach($responseResult['result'] as $response)
			{
		        echo '<dd>';
		                    		
				if($response['is_anonymous']!='1')
				{   				
				    $userResult=$userDAO->GetUserByID($response['user_id']);
		            
				    echo '<div class="reply_1">
				    		<a href="'.edp_href_link(PAGENAME_USER_INFO, 'uid='.$userResult['id']).'">            
				   			 <img src="'.EdpGetAvatarUrl($userResult['logo_path']).'" width="40" height="40"/>		                       	          
		            		</a></div>';                   
		            echo '<div class="reply_2"><h1><span><a href="'.edp_href_link(PAGENAME_USER_INFO, 'uid='.$userResult['id']).'">'.$userResult['nick'].'</a></span><div class="degree_box"> <span class="'.getUserRankClass($userResult['contribution']).'" alt="" ></span></div><span> 发表于 '.$response['date'].'</span></h1><h2>#'.$responseCount.'</h2></div>';
		  
		         }else{ 	
		         	
		         	$response['user_ip'] = preg_replace('/((?:\d+\.){3})\d+/', "\\1*", $response['user_ip']);
		         	echo '<div class="reply_1">
		         			<img src="'.DEFAULT_AVATAR_URL.'" width="40" height="40"  />
		         		</div>';
		         	echo '<div class="reply_2"><h1><span>匿名用户 | '.$response['user_ip'].' </span><span>发表于 '.$response['date'].'</span></h1><h2>#'.$responseCount.'</h2></div>';	   
				 }
				  
				 echo '<div class="reply_3">';
				 secho($response['content']);
		         echo '</div></dd>';
		         
		         $responseCount = $responseCount + 1;
				 } 	
		}	 	 	  
	?>

		</dl>
		
<?php  } ?>    		
    	<!-- 回应列表end -->
 
 
    	<!-- 我的回应begin -->
		<div class="form_box">
			<a name="reply_point" > </a>  
      <form action="<?php echo edp_href_link(PAGENAME_LIST_INFO,"lid=$lid");?>" method="POST" onsubmit="return check_validation();"  grayOnCommit=".form_box" id="addResponseForm">
				<input type="hidden" name="action" value="addResponse" />
				<div class="form_top"></div>
				<div class="form_middle">
					<div class="form_item">
						<h1>我的回应</h1><h2><textarea class="form_textarea" name="response" id="response"><?php global $responseContent; if(isset($responseContent)) secho(  $responseContent ) ; ?></textarea></h2>
					</div>   

					 <?php
					 if($logid){
					 ?>		
					  <div class="form_item">
						<h1></h1>
						<h2>
					    	<input type="radio" id="post_login" name="post_author_type" /><span><?php secho( edp_getsession('username') ); ?></span>
						    <input type="radio" id="post_anonym" name="post_author_type" /><span>匿名回复 </span>
						</h2>
				      </div>               
					<?php 	
						}else{
					 ?>							
					   <div class="form_item">
						<h1></h1>
						<h2>
						<input type="hidden" name="post_author_type" value='0'/>
					    	如果要发表回复 请<a href="<?php echo edp_href_link(PAGENAME_LOGIN); ?>"> 登录 </a>或者<a href="<?php echo edp_href_link(PAGENAME_REGISTER); ?>"> 注册</a>  
						</h2>
				       </div>  
					   
					<?php		
						}					
				 	?>     		
					   
					   <div class="form_item">
						<h1></h1>
						<h2>
							<div class="form_title">验证码：</div>
		                    <input type="text" id="vcode" name="vcode" class="form_text"/> 
						</h2>
					   </div>
						  
					   <div class="form_item" id="vbox">
						<h1></h1>
						<h2>
		                    <img id='vimg'  src="" />&nbsp;&nbsp;<a href="javascript:refresh_vcode('vcode/?tiny='+Math.random());">换一张</a>                    
						</h2>						
				       </div>  

					<div class="form_item">
						<h1></h1>
						<h2>                                	
							<input type="submit"  class="btn_1" value="提交回应"/>                                    
						</h2>
					</div>
				</div>
				<div class="form_bottom"></div>
			</form>
		</div>
    	<!-- 我的回应end -->
      
  </div>